<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
<%@ taglib uri="http://myfaces.apache.org/tomahawk" prefix="t"%>
<%@ taglib uri="http://richfaces.org/a4j" prefix="a4j"%>
<%@ taglib uri="http://richfaces.org/rich" prefix="rich"%>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-tiles"
	prefix="tiles"%>

<rich:panel header="#{messages['create.complaint']}">
	<h:panelGrid>
		<h:outputText value="#{errorBean.errorMessage}" styleClass="error"></h:outputText>
	</h:panelGrid>
	
	<t:panelGrid columns="2" columnClasses="standardTable_ColumnLeft_20,standardTable_ColumnLeft_80" width="100%">

		<h:outputText></h:outputText>
		<t:message for="title" styleClass="error"></t:message>

		<h:panelGroup>
			<h:outputText value="*" styleClass="standardText_Mandatory" />
			<h:outputLabel for="title" value="#{messages['title']}" styleClass="standardText_Label" />
		</h:panelGroup>
		<h:panelGroup>
			<t:inputText id="title" required="true" size="50" maxlength="50" styleClass="standardText" value="#{agentComplaintBean.complaint.title}"></t:inputText>
		</h:panelGroup>
		
		<h:outputText></h:outputText>
		<t:message for="detail" styleClass="error"></t:message>

		<h:panelGroup>
			<h:outputText value="*" styleClass="standardText_Mandatory" />
			<h:outputLabel for="detail" value="#{messages['detail']}" styleClass="standardText_Label" />
		</h:panelGroup>
		<h:panelGroup>
			<t:inputTextarea id="detail" required="true" cols="50" rows="30" value="#{agentComplaintBean.complaint.detail}">
			</t:inputTextarea>
		</h:panelGroup>
		
	</t:panelGrid>
	
	<t:panelGrid columns="2" width="100%" columnClasses="standardTable_ColumnLeft_20,standardTable_ColumnLeft_80">
		<h:outputText></h:outputText>
		<t:panelGroup>
		 	<h:commandButton value="#{messages['create']}" styleClass="button"  action="#{agentComplaintBean.createAction}"></h:commandButton>
		 	<f:verbatim>&nbsp;</f:verbatim>
   			<h:commandButton value="#{messages['cancel']}" styleClass="button" immediate="true" action="#{agentComplaintBean.navListAction}"></h:commandButton>
   		</t:panelGroup>
	</t:panelGrid>
	
</rich:panel>